/* 按钮基本样式 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 400;
  text-align: center;
  vertical-align: middle;
  user-select: none;
  padding: 0.375rem 0.75rem;
  font-size: 1rem;
  line-height: 1.5;
  border-radius: 0.25rem;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, 
             border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  text-decoration: none;
  cursor: pointer;
}

/* 主要按钮 */
.btn-primary {
  color: #fff;
  background-color: var(--primary-color, #0d6efd);
  border-color: var(--primary-color, #0d6efd);
}

.btn-primary:hover {
  color: #fff;
  background-color: #0b5ed7;
  border-color: #0a58ca;
}

.btn-primary:focus {
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.5);
}

.btn-primary:disabled {
  color: #fff;
  background-color: var(--primary-color, #0d6efd);
  border-color: var(--primary-color, #0d6efd);
  opacity: 0.65;
  cursor: not-allowed;
}

/* 轮廓原色按钮 */
.btn-outline-primary {
  color: var(--primary-color, #0d6efd);
  border-color: var(--primary-color, #0d6efd);
  background-color: transparent;
}

.btn-outline-primary:hover {
  color: #fff;
  background-color: var(--primary-color, #0d6efd);
  border-color: var(--primary-color, #0d6efd);
}

.btn-outline-primary:focus {
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.5);
}

/* 警告按钮 */
.btn-warning {
  color: #000;
  background-color: var(--warning-color, #ffc107);
  border-color: var(--warning-color, #ffc107);
}

.btn-warning:hover {
  color: #000;
  background-color: #ffca2c;
  border-color: #ffc720;
}

.btn-warning:focus {
  box-shadow: 0 0 0 0.25rem rgba(255, 193, 7, 0.5);
}

/* 轮廓次要按钮 */
.btn-outline-secondary {
  color: var(--secondary-color, #6c757d);
  border-color: var(--secondary-color, #6c757d);
  background-color: transparent;
}

.btn-outline-secondary:hover {
  color: #fff;
  background-color: var(--secondary-color, #6c757d);
  border-color: var(--secondary-color, #6c757d);
}

/* 危险按钮 */
.btn-danger {
  color: #fff;
  background-color: var(--danger-color, #dc3545);
  border-color: var(--danger-color, #dc3545);
}

.btn-danger:hover {
  color: #fff;
  background-color: #bb2d3b;
  border-color: #b02a37;
}

.btn-danger:focus {
  box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.5);
}

/* 按钮组样式 */
.btn-group {
  position: relative;
  display: inline-flex;
  vertical-align: middle;
}

.btn-group .btn {
  position: relative;
  flex: 1 1 auto;
  padding: 0.25rem 0.5rem;
  margin: 0 1px;
}

.btn-group .btn:hover {
  z-index: 3;
}

/* 图标按钮动画效果 */
.btn i {
  transition: transform 0.2s;
}

.btn:hover i {
  transform: scale(1.1);
}

/* 小按钮样式 */
.btn-sm {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  border-radius: 0.2rem;
}

/* 按钮文本 */
.btn-text {
  margin-left: 0.5rem;
  font-size: 0.95rem;
  font-weight: 400;
}

/* 操作按钮样式 - 用于导出、导入、保存等操作 */
.action-buttons {
  display: flex;
  flex-direction: row;
  flex-wrap: auto;
  gap: 8px;
  flex-shrink: 0;
}

.action-buttons .btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 14px;
  min-width: auto;
  height: 38px;
}

.action-buttons .btn i {
  font-size: 16px;
  margin-right: 0;
}

/* 在大屏幕上显示按钮文本 */
@media (min-width: 960px) {
    .btn{
        padding: 4px 8px !important;  
    }
    .btn-text {
        font-size: 1rem !important;
    }
}

/* 在小屏幕上隐藏按钮文本 */
@media (max-width: 959px) {
    .btn{
        padding: 2px 4px !important;  
    }
    .btn-text {
        font-size: 0.8rem !important;
    }
} 